<template>
	<view class="content">
		<view class="statusBox"></view>
		<view class="searchBox width90 padding5">
			<view class="clockBox" @tap="TapBack">
				<image class="iconClock" src="/static/index/icon_back.png" mode=""></image>
			</view>
			<view class="search">
				<uni-icons class="icons" type="search" color="#999999" size="16"/>
				<input class="searchInput" :value="inputValue" type="text" placeholder="请输入关键词" @input="getValue" @confirm="searBtn">
			</view>
			<view class="clearBoth"></view>
		</view>
		<view class="storeBox">
			<image class="logo" :src="storeData.logo" mode=""></image>
			<view class="right">
				<view class="name overflow_one">{{storeData.name}}</view>
				<view class="names">商品数</view>
				<view class="color_orange fontSemiBold">{{storeData.number}}</view>
				<view class="name_splite">|</view>
				<view class="names">关注度</view>
				<view class="color_orange fontSemiBold">{{storeData.attentionNumber}}</view>
				<view class="clearBoth"></view>
				<view class="otherList" v-for="(item,index) in storeData.otherFunc" :key="index">{{item.name}}</view>
				<view class="clearBoth"></view>
			</view>
			<view class="fontSize12" @tap="btnAttention" :class="storeData.isAttention?'attentions':'attention' ">{{storeData.isAttention?'已关注':'关注'}}</view>
			<view class="clearBoth"></view>
		</view>
		<view class="splite"></view>
		
		<view class="titleBox">
			<view class="scrollBox">
				<view class="titleRows" v-for="(item,index) in titleList" :key="index" @tap="thisTitle(item.id,index)">
					<view class="titleName fontSize14 textCenter" :class=" item.thisOne ? 'chooseThis':'' ">{{item.name}}</view>
					<view class="titleIcon" v-if="item.thisOne"></view>
				</view>
			</view>
			<view class="clearBoth"></view>
		</view>
		
		<view class="pages_home" v-if="titleList[0].thisOne">
			<!-- <view class="maxImageBox">
				<image class="maxImage border10" src="../../../static/del/del_1.png" mode=""></image>
			</view> -->
			
			<uni-swiper-dot class="swiper" :info="bannerList" :current="current" mode="round" :dotsStyles="dotsStyles">
				<swiper class="swiper-box swiper" @change="change" autoplay="autoplay" circular="true">  
					<swiper-item v-for="(item, indexc) in bannerList" :key="indexc"  @tap="tapBanner(item)">
						<image class="swiperitem banner"  :src="item.src"/>  
					</swiper-item>
				</swiper>
			</uni-swiper-dot>
			
			
			<view class="scrollMaxBox">
				<view class="scrollBox" :style="{width:scrollWidth}">
					<view class="scroll" v-for="(item,index) in storeThings" :key="index" @tap="inMDetails(item.id)">
						<image class="cover border10" :src="item.poster" mode="aspectFill"></image>
						<view class="byType">{{item.typeName}}</view>
						<view class="title fontSize14 overflow_one">{{item.title}}</view>
						<view class="priceBox">
							<view class="price fontSize14 fontSemiBold">￥{{item.price}}</view>
							<s class="beforePrice">￥{{item.beforePrice}}</s>
						</view>
					</view>
				</view>
			</view>
			<view class="other">
				<view class="titleBox">
					<image class="icon" src="/static/index/details/icon_2.png" mode=""></image>
					<view class="name">推荐商品</view>
					<image class="icon" src="/static/index/details/icon_2.png" mode=""></image>
				</view>
				<view class="proList">
					<view class="proRows" v-for="(item,index) in rowsList" :key="index" @tap="inDetails(item.id)">
						<image class="cover" :src="item.cover" mode=""></image>
						<view class="HisTitle fontSize14 overflow_two">{{item.title}}</view>
						<!-- <view class="typeBoxs">
							<view class="type" v-for="(items,indexs) in item.type" :key="indexs">{{items.name}}</view>
						</view> -->
						<view class="clearBoth"></view>
						<view class="priceBox">
							<view class="price">¥<view class="priceTip">{{item.price}}</view></view>
							<s class="priceBefore">¥ {{item.priceBefore}}</s>
							<view class="user" v-show="item.use">已拼{{item.use}}件</view>
							<view class="clearBoth"></view>
						</view>
					</view>
				</view>
			</view>
		</view>
		<view class="pages_home" v-if="titleList[1].thisOne">
			<view class="other">
				<view class="proList">
					<view class="proRows" v-for="(item,index) in rowsList_goods" :key="index" @tap="inDetails(item.id)">
						<image class="cover" :src="item.cover" mode=""></image>
						<view class="HisTitle fontSize14 overflow_two">{{item.title}}</view>
						<!-- <view class="typeBoxs">
							<view class="type" v-for="(items,indexs) in item.type" :key="indexs">{{items.name}}</view>
						</view> -->
						<view class="clearBoth"></view>
						<view class="priceBox">
							<view class="price">¥<view class="priceTip">{{item.price}}</view></view>
							<s class="priceBefore">¥ {{item.priceBefore}}</s>
							<view class="user" v-show="item.use">已拼{{item.use}}件</view>
							<view class="clearBoth"></view>
						</view>
					</view>
				</view>
			</view>
		</view>
		<view class="pages_home" v-if="titleList[2].thisOne">
			<view class="other">
				<view class="proList">
					<view class="proRows" v-for="(item,index) in rowsList_activity" :key="index" @tap="inDetails(item.id)">
						<image class="cover" :src="item.cover" mode=""></image>
						<view class="HisTitle fontSize14 overflow_two">{{item.title}}</view>
						<!-- <view class="typeBoxs">
							<view class="type" v-for="(items,indexs) in item.type" :key="indexs">{{items.name}}</view>
						</view> -->
						<view class="clearBoth"></view>
						<view class="priceBox">
							<view class="price">¥<view class="priceTip">{{item.price}}</view></view>
							<s class="priceBefore">¥ {{item.priceBefore}}</s>
							<view class="user" v-show="item.use">已拼{{item.use}}件</view>
							<view class="clearBoth"></view>
						</view>
					</view>
				</view>
			</view>
		</view>
		<view class="pages_home" v-if="titleList[3].thisOne">
			<view class="other">
				<view class="proList">
					<view class="proRows" v-for="(item,index) in rowsList_new" :key="index" @tap="inDetails(item.id)">
						<image class="cover" :src="item.cover" mode=""></image>
						<view class="HisTitle fontSize14 overflow_two">{{item.title}}</view>
						<!-- <view class="typeBoxs">
							<view class="type" v-for="(items,indexs) in item.type" :key="indexs">{{items.name}}</view>
						</view> -->
						<view class="clearBoth"></view>
						<view class="priceBox">
							<view class="price">¥<view class="priceTip">{{item.price}}</view></view>
							<s class="priceBefore">¥ {{item.priceBefore}}</s>
							<view class="user" v-show="item.use">已拼{{item.use}}件</view>
							<view class="clearBoth"></view>
						</view>
					</view>
				</view>
			</view>
		</view>
		<view class="pages_home html" v-if="titleList[4].thisOne" v-html="storeData.richText"></view>
		

	</view>
</template>
<style>
	.content{}
	.content .swiper{width:100%;height:690upx;margin-top: 5upx;overflow: hidden;}
	.content .banner{width:95%;margin-left:2.5%;height:630upx;border-radius:10upx;}
	.content .swipers{width:95%;margin-left: 2.5%;height:690upx;margin-top:25upx;overflow: hidden;}
	.content .swipers .iconSwiper{height:690upx;display: flex;justify-content:space-around;flex-wrap: wrap;}
	.content .swipers .iconList{width: 20%;height:130upx;display: flex;justify-content:center;flex-wrap: wrap;}
	.content .swipers .biggerIcon{width: 80upx;height:80upx;margin: 0 20upx;}
	.content .swipers .lessIcon{width: 52upx;height:52upx;margin:0 10upx;}
	.content .splite{width: 100%;height:10upx;background: rgb(245,245,249);margin-top:40upx;margin-bottom: 20upx;}
	.searchBox{background: white;margin-top: 52upx;margin-bottom: 20upx;margin-left: 5%;}
	.searchBox .search{width:60%;padding:0 2.5%;height:56upx;line-height: 56upx;float:left;background:rgb(245,245,249);border-radius: 100upx;position: relative;}
	.searchBox .search .icons{margin-left:10upx;float: left;}
	.searchBox .search .btnSearch{float: right;width:20%;text-align: center;position: absolute;top:0;right:-20%;font-size: 14px;}
	.searchBox .search .searchInput{width:70%;color:#999999;font-size: 14px;height:56upx;line-height: 56upx;margin-left:20upx;float: left;}
	.searchBox .search .uni-input-placeholder{font-size: 14px;}
	.searchBox .clockBox{width:10%;float: left;position: relative;}
	.searchBox .clockBox .iconClock{width:24upx;height:40upx;float: left;margin-top: 8upx;}
	.content .storeBox{width:95%;margin-left: 2.5%;margin-top: 40upx;}
	.content .storeBox .logo{width:120upx;height: 120upx;float: left;margin-right: 5%;border-radius: 10upx;}
	.content .storeBox .right{width: 60%;float: left;}
	.content .storeBox .right .name{max-width: 100%;font-weight: bold;font-size: 32upx;color:#262626;margin-bottom:5upx;}
	.content .storeBox .right .names{color:#999999;font-size: 24upx;float: left;}
	.content .storeBox .right .color_orange{height: 32upx;line-height: 32upx;color:#DC582A;font-size: 24upx;float: left;margin-left:10upx}
	.content .storeBox .right .name_splite{color:999999;font-size: 24upx;float: left;margin:0 20upx}
	.content .storeBox .right  .otherList{margin-right: 20upx;margin-top: 10upx;font-size: 18upx;color:#DC582A;background: rgba(251,238,233);float: left;}
	.content .storeBox .attention{width:15%;height:50upx;line-height: 50upx;margin-top:35upx;text-align: center;float: right;background: rgb(220,88,42);color:white;border-radius: 200upx;}
	.content .storeBox .attentions{width:15%;height:50upx;line-height: 50upx;margin-top:35upx;text-align: center;float: right;background: rgb(245,245,249);color:#999999;border-radius: 200upx;}
	.content .titleBox{width: 95%;height: 60upx;margin-left: 2.5%;overflow-x: scroll;}
	.content .titleBox .scrollBox{width: auto;height: 60upx;overflow-x: scroll;}
	.content .titleBox .titleRows{width:20%;float: left;}
	.content .titleBox .titleRows .titleName{font-size: 28upx;color:#1A191E;font-weight: bold;}
	.content .titleBox .titleRows .titleIcon{width:20%;height:6upx;margin-top: 5upx;margin-left: 40%;border-radius: 100upx;background: rgb(220,88,42);}
	.content .titleBox .titleRows .chooseThis{font-size: 14px;color:rgb(220,88,42)}
	.content .pages_home{width:95%;margin-left: 2.5%;margin-top: 20upx;}
	.content .pages_home .border10{border-radius: 10upx;}
	.content .pages_home .maxImageBox{width: 95%;margin-left: 2.5%;display: flex;justify-content: center;}
	.content .pages_home .maxImageBox .maxImage{width: 100%;height: 690upx;}
	.content .pages_home .scrollMaxBox{width: 95%;margin-left: 2.5%;margin-top: 0upx;overflow-x: scroll;}
	.content .pages_home .scrollMaxBox .scrollBox{width:auto;overflow-x: scroll;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll{width: 214upx;float: left;margin-right:16upx;display: flex;justify-content: center;flex-wrap: wrap;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .cover{width: 100%;height:214upx;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .byType{width: 60%;margin:20upx 0 20upx 0;text-align: center;border-radius: 5upx;font-size: 20upx;color:#DC582A;background: rgb(249,229,222);}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .title{width: 100%;color:#333333;font-weight: bold;text-align: center;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .priceBox{width: 100%;text-align: center;display: flex;justify-content: center;margin-top: 20upx;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .priceBox .price{float: left;color:#DC582A;font-weight: bold;}
	.content .pages_home .scrollMaxBox .scrollBox .scroll .priceBox .beforePrice{float: left;color:#CED3DD;font-size: 20upx;}
	.content .other{width: 100%;padding-top: 0upx;}
	.content .other .titleBox{width: 100%;display: flex;justify-content: center;margin:50upx 0 10upx 0}
	.content .other .titleBox .icon{width: 32upx;height:20upx;margin:0 30upx;margin-top: 15upx;}
	.content .other .titleBox .name{height: 50upx;line-height: 50upx;color:#30313B;font-weight: bold;font-size: 36upx;}
	.content .proList{width: 95%;margin-left: 2.5%;display: flex;justify-content:left;flex-wrap: wrap;}
	.content .proList .proRows{width:47.5%;margin:15upx 1.25% 15upx 1.25%;background: white;border-radius: 10upx;padding-bottom: 10upx;}
	.content .proList .proRows .cover{width: 100%;height:336upx;border-radius: 10upx;}
	.content .proList .proRows .HisTitle{font-weight: bold;margin-left: 5%;height:76upx}
	.content .proList .proRows .typeBoxs{height:96upx;margin-left: 5%;}
	.content .proList .proRows .type{font-size: 20upx;float: left;margin:5upx;padding:5upx;border-radius: 10upx;color:#DC582A;background:rgb(251,238,233);}
	.content .proList .proRows .priceBox{width: 100%;margin-top: 10upx;margin-left: 5%;}
	.content .proList .proRows .priceBox .price{float:left;font-size: 24upx;color:#262626;margin-right: 5upx;font-weight: bold;font-family: hzgb;}
	.content .proList .proRows .priceBox .priceTip{float: right;margin-left:5upx;font-size: 32upx;color:#262626;margin-right: 5upx;font-weight: bold;font-family: hzgb;position: relative;top:-4upx}
	.content .proList .proRows .priceBox .priceBefore{float:left;color:#999999;font-size: 20upx;}
	.content .proList .proRows .priceBox .user{width: 95%;margin-left:5%;float:right;font-size: 24upx;margin-right: 8%;color:#999999;}
</style>
<script>
	import Share from '@/common/wx_share.js'
	export default {
		data() {
			return {
				share:{
					title:"",
					path:'/pages_index/pages/store_home/store_home',
					imageUrl:'',
					desc:'',
					content:''
				},
				bannerList:[
					// {src:"/static/index/banner.png"},
					// {src:"/static/index/banner.png"},
					// {src:"/static/index/banner.png"}
				],
				current:0,
				dotsStyles:{
					bottom:40,
					backgroundColor: 'rgba(255,255,255,0.5)',
					border: '1px solid none',
					color: 'none',
					selectedBackgroundColor: 'white',
					selectedBorder: '1px none solid'
				},
				inputValue:"",
				storeData:{
					logo:"",
					name:"",
					number:"",
					attentionNumber:"",
					richText:"",
					otherFunc:[
						// {name:""},
					],
					isAttention:"",
				},
				titleList:[
					{id:1,name:"首页",thisOne:true},
					{id:2,name:"商品",thisOne:false},
					{id:3,name:"活动",thisOne:false},
					{id:4,name:"上新",thisOne:false},
					{id:5,name:"简介",thisOne:false},
				],
				storeThings:[
					// {id:1,poster:"../../../static/del/del_9.png",typeName:"限时秒杀",title:"稻草稻草人小夜灯人小夜灯1",price:"123",beforePrice:"150"},
					// {id:2,poster:"../../../static/del/del_9.png",typeName:"限时秒杀",title:"稻草人小夜灯2",price:"123",beforePrice:"150"},
					// {id:3,poster:"../../../static/del/del_9.png",typeName:"限时秒杀",title:"稻草人小夜灯3",price:"123",beforePrice:"150"},
					// {id:4,poster:"../../../static/del/del_9.png",typeName:"限时秒杀",title:"稻草人小夜灯4",price:"123",beforePrice:"150"},
				],
				scrollWidth:"",
				rowsList:[
					// {id:1,cover:"/static/del/del_3.png",title:"描述述描描述述描述述描述述描述述描述述描述述述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:2,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]}
				],
				rowsList_goods:[
					// {id:1,cover:"/static/del/del_3.png",title:"描述述描描述述描述述描述述描述述描述述描述述述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:2,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
				],
				rowsList_activity:[
					// {id:1,cover:"/static/del/del_3.png",title:"描述述描描述述描述述描述述描述述描述述描述述述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:2,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
				],
				rowsList_new:[
					// {id:1,cover:"/static/del/del_3.png",title:"描述述描描述述描述述描述述描述述描述述描述述述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:2,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:1,cover:"/static/del/del_3.png",title:"描述述描描述述描述述描述述描述述描述述描述述述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]},
					// {id:2,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"}]},
					// {id:3,cover:"/static/del/del_3.png",title:"描述述描述述描述述描述述描述述描述述",price:"1",priceBefore:"12",use:"123",type:[{name:"旗舰店"},{name:"退货包运费"},{name:"退货包运费"}]}
				],
				stroeId:"",
				pages:1,
				
				
				
			}
		},
		onLoad(e){
			this.share.path = this.share.path +"?id="+ e.id
			this.stroeId = e.id
			this.AjaxLoad(e.id)
			this.AjaxLoadListHome()
		},
		onReachBottom(){
			this.pages++
			
		},
		methods: {
			thisTitle(id,index){
				for (var i = 0; i < this.titleList.length; i++) {
					this.titleList[i].thisOne = false
				}
				this.titleList[index].thisOne = true
				this.pages = 1
				this.rowsList = []
				this.rowsList_goods = []
				this.rowsList_activity = []
				this.rowsList_new = []
				if( id == 1 ){
					this.AjaxLoadListHome()
				}else if( id == 2 ){
					this.AjaxLoadListGoods()
				}else if( id == 3 ){
					this.AjaxLoadListActivity()
				}else if( id == 4 ){
					this.AjaxLoadListNew()
				}else if( id == 5 ){}
			},
			AjaxLoadListNew(){
				var rowsList_new = []
				let params={
					token:this._$userToken("userInfo").token,
					shop_id:this.stroeId,
					page:this.pages
				};
				this._$InitRequest.request('shops/now', params).then(res => {
					res.data.goodres.forEach( (item) =>{
						rowsList_new.push({
							id:item.id,
							cover:item.thumb_url,
							title:item.goods_name,
							price:item.min_price,
							priceBefore:item.max_price,
							use:item.pin_num,
						})
					})
					for (var i = 0; i < rowsList_new.length; i++){this.rowsList_new.push( rowsList_new[i] )}
				},error=>{})
			},
			AjaxLoadListActivity(){
				var rowsList_activity = []
				let params={
					token:this._$userToken("userInfo").token,
					shop_id:this.stroeId,
					page:this.pages
				};
				this._$InitRequest.request('shops/getralst', params).then(res => {
					res.data.forEach( (item) =>{
						rowsList_activity.push({
							id:item.id,
							cover:item.thumb_url,
							title:item.goods_name,
							price:item.min_price,
							priceBefore:item.max_price,
							use:item.pin_num,
						})
					})
					for (var i = 0; i < rowsList_activity.length; i++){this.rowsList_activity.push( rowsList_activity[i] )}
				},error=>{})
			},
			AjaxLoadListGoods(){
				var rowsList_goods = []
				let params={
					token:this._$userToken("userInfo").token,
					shop_id:this.stroeId,
					page:this.pages
				};
				this._$InitRequest.request('shops/goods_list', params).then(res => {
					res.data.goodres.forEach( (item) =>{
						rowsList_goods.push({
							id:item.id,
							cover:item.thumb_url,
							title:item.goods_name,
							price:item.min_price,
							priceBefore:item.max_price,
							use:item.pin_num,
						})
					})
					for (var i = 0; i < rowsList_goods.length; i++){this.rowsList_goods.push( rowsList_goods[i] )}
				},error=>{})
			},
			AjaxLoadListHome(){
				var rowsList = []
				let params={
					token:this._$userToken("userInfo").token,
					shop_id:this.stroeId,
					page:this.pages
				};
				this._$InitRequest.request('shops/recommend', params).then(res => {
					res.data.goodres.forEach( (item) =>{
						rowsList.push({
							id:item.id,
							cover:item.thumb_url,
							title:item.goods_name,
							price:item.min_price,
							priceBefore:item.max_price,
							use:item.pin_num,
						})
					})
					for (var i = 0; i < rowsList.length; i++){this.rowsList.push( rowsList[i] )}
				},error=>{})
			},
			
			
			
			
			AjaxLoad(e){
				uni.showLoading({
					title:"加载中..."
				})
				var bannerList = [],otherFunc = [],storeThings = []
				var goodsId="",storeId=""
				let param={
					token:this._$userToken("userInfo").token,
					shop_id:e
				};
				this._$InitRequest.request("shops/shopinfo", param).then(res => {
					// storeData:{
					// 	logo:"/static/del/del_11.png",
					// 	name:"店铺名字",
					// 	number:"123",
					// 	attentionNumber:"321",
					// 	richText:"",
					// 	otherFunc:[
					// 		{name:"限时秒杀"},
					// 		{name:"24小时在线"},
					// 	],
					// 	isAttention:false,
					// },
					this.storeData.logo = res.data.shops.logo
					this.storeData.name = res.data.shops.shop_name
					this.storeData.number = res.data.shops.goods_num
					this.storeData.attentionNumber = res.data.shops.colls_num
					if( res.data.shops.coll_shops == 1 ){
						this.storeData.isAttention = true
					}else{
						this.storeData.isAttention = false
					}
					
					
					//banner
					res.data.banner.forEach( (item) =>{
						if( item.url.split(":")[0] == 1 ){
							goodsId = item.url.split(":")[1]
						}else if( item.canshu.split(":")[0] == 2 ){
							storeId = item.url.split(":")[1]
						}
						bannerList.push({
							id:item.id,
							goodsId:goodsId,
							storeId:storeId,
							canshu:item.url,
							src:item.pic_url,
						})
					})
					for (var i = 0; i < bannerList.length; i++){this.bannerList.push( bannerList[i] )}
					
					//tip
					res.data.tips.forEach( (item) =>{
						otherFunc.push({
							name:item,
						})
					})
					for (var i = 0; i < otherFunc.length; i++){this.storeData.otherFunc.push( otherFunc[i] )}
					
					//秒杀
					res.data.cxgoodres.forEach( (item) =>{
						storeThings.push({
							id:item.id,
							poster:item.thumb_url,
							typeName:"限时秒杀",
							title:item.goods_name,
							price:item.zs_price,
							beforePrice:item.min_price
						})
					})
					for (var i = 0; i < storeThings.length; i++){this.storeThings.push( storeThings[i] )}
					
					this.scrollWidth = this.storeThings.length * 115  + "px"
					
					
				},error=>{})
				
				let params={
					token:this._$userToken("userInfo").token,
					shop_id:e
				};
				this._$InitRequest.request('shops/shop_content', params).then(res => {
					this.storeData.richText = res.data.content
				},error=>{})

				setTimeout(function(){
					uni.hideLoading()
				},500)
			},
			TapBack(){
				uni.navigateBack({
					delta:1
				})
			},
			change(e){this.current = e.detail.current},
			getValue(e){this.inputValue = e.target.value},
			searBtn(){console.log(this.inputValue)},
			btnAttention(){
				if( this.storeData.isAttention == false ){
					this.storeData.isAttention = true
					let param={
						token:this._$userToken("userInfo").token,
						shop_id:this.stroeId
					};
					this._$InitRequest.request('CollShops/coll', param).then(res => {
						uni.showToast({title:res.mess,icon:"none"})
					},error=>{})
				}else{
					this.storeData.isAttention = false
					let param={
						token:this._$userToken("userInfo").token,
						shop_id:this.stroeId
					};
					this._$InitRequest.request('CollShops/cancelcoll', param).then(res => {
						uni.showToast({title:res.mess,icon:"none"})
					},error=>{})
				}
			},
			inDetails(id){
				uni.navigateTo({
					url:"/pages_index/pages/details/details?id=" + id
				})
			},
			inMDetails(id){
				uni.navigateTo({
					url:"/pages_index/pages/seckill/details?id=" + id
				})
			},
			tapBanner(e){
				if( e.goodsId ){
					uni.navigateTo({
						url:"/pages_index/pages/details/details?id=" + e.goodsId
					})
				}
				if( e.storeId ){
					uni.navigateTo({
						url:"/pages_index/pages/store_home/store_home?id=" + e.storeId
					})
				}
			},
			
			
			
			
			
		}
	}
</script>
<style lang="scss" scoped>
/deep/ .uni-input-input {font-size:32upx}
/deep/ .uni-radio-input-checked{background-color:rgb(110,43,34) !important;border:2upx solid white !important}
.content .html{
  ::v-deep {
    img {
      width: 100%;
    }
  }
}
</style>